package com.perceptivesoftware.licensing.login.client;

import com.google.gwt.core.client.GWT;
import com.google.gwt.user.client.rpc.AsyncCallback;
import com.perceptivesoftware.licensing.login.client.rpc.LoginService;
import com.perceptivesoftware.licensing.login.client.rpc.LoginServiceAsync;
import com.perceptivesoftware.login.client.LoginScreen;

public class LicensingLoginScreen extends LoginScreen {

	public LicensingLoginScreen() {
		super();
		((LoginServiceAsync) GWT.create(LoginService.class)).getLoginPageVersion(new AsyncCallback<String>() {

			@Override
			public void onSuccess(String result) {
				setVersion(result);
			}

			@Override
			public void onFailure(Throwable caught) {
				// MessageBox.alert("Version Info",
				// "Unable to retrieve version information", null);
			}
		});
	}

	@Override
	public String getImageStyle() {
		return "perceptive-login-image";
	}

	@Override
	public String getBackgroundColor() {
		return "ffffff";
	}
}
